package com.zoweunion.mechanic.dao;

import com.zoweunion.mechanic.entity.TSSsUserEntity;
import com.zoweunion.mechanic.entity.dto.TSSsUserDTO;
import com.zoweunion.mechanic.entity.vo.TSSsUserVO;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.toolkit.Constants;

import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;


/**
 * ${comments}
 *
 * @author wxx
 * @date 2023-05-24 11:33:02
 */
@Mapper
public interface TSSsUserMapper extends BaseMapper<TSSsUserEntity> {

    /**
     * 查询所有数据
     *
     * @return
     */
    List<TSSsUserEntity> listShow();

    /**
     * 查询记录条数
     *
     * @return
     */
    int countByCondition(TSSsUserDTO tSSsUser);

    /**
     * 条件查询数据
     *
     * @return
     */
    List<TSSsUserVO> findByCondition(Map<String, Object> map);

    /**
     * 根据服务商ID获取所有非车主司机用户信息(重写之前的方法)
     *
     * @return
     */
    List<TSSsUserVO> getAllUserBySid(@Param("s_id") String sId);

    /**
     * 条件查询数据分页
     *
     * @param page
     * @param queryWrapper
     * @return
     */
    Page<TSSsUserVO> selectListPage(Page<TSSsUserDTO> page, @Param(Constants.WRAPPER) QueryWrapper<TSSsUserDTO> queryWrapper);


    /**
     * 条件查询taskNo
     *
     * @param queryWrapper
     * @return
     */
    List<TSSsUserVO> selectTaskNo(@Param(Constants.WRAPPER) QueryWrapper<TSSsUserDTO> queryWrapper);


}

